@model CaipuGuanliXitong.Models.CookBook

@{
    ViewData["Title"] = "编辑菜谱";
}

<h2>编辑菜谱</h2>

<h4>菜谱信息</h4>
<hr />
<div class="row">
    <div class="col-md-4">
        <form asp-action="Edit">
            <div asp-validation-summary="ModelOnly" class="text-danger"></div>
            <input type="hidden" asp-for="Id" />
            <input type="hidden" asp-for="CreatedTime" />
            <div class="form-group">
                <label asp-for="Name" class="control-label">菜谱名称</label>
                <input asp-for="Name" class="form-control" />
                <span asp-validation-for="Name" class="text-danger"></span>
            </div>
            <div class="form-group">
                <label asp-for="Category" class="control-label">分类</label>
                <input asp-for="Category" class="form-control" />
                <span asp-validation-for="Category" class="text-danger"></span>
            </div>
            <div class="form-group">
                <label asp-for="UpdatedTime" class="control-label">修改时间</label>
                <input asp-for="UpdatedTime" class="form-control" readonly />
            </div>
            <div class="form-group">
                <input type="submit" value="保存" class="btn btn-primary" />
                <a asp-action="Index" class="btn btn-default">返回列表</a>
            </div>
        </form>
    </div>
</div>

@section Scripts {
    @{await Html.RenderPartialAsync("_ValidationScriptsPartial");}
}